package com.itlong.cloud.POJO.VO.app;

import lombok.Getter;
import lombok.Setter;

import java.util.List;

/**
*<desc>
*   APP端用户缓存对象
*</desc>
 @createDate 2017/09/29
*/
@Getter
@Setter
public class AppUserCacheVO  {
    private Integer id;
    private String userId;  //用户ID
    private String userName; //用户姓名
    private String nickName; //用户昵称
    private String phoneNo;  //用户手机号
    private String email;    //邮箱用户
    private String photoUrl;  //头像地址
    private String sex; //0女、1男
    private String token; //手机号+"_"+用户ID后加密
    private String miniToken; //手机号+"_"+用户ID后加密  小程序用
    private String loginDevice;     //用户登录终端类型，1-android,2-iOS
    private String currentProjectId;  //当前选中项目编号
    private String currentProjectName; //当前选中项目名称
    private String forbidden;          //是否欠费禁用 1禁用、0启用
    private Integer currentProjectType;  //当前项目类型 0社区 1园区 2酒店 3医院
    private String currentOwnerAddress;     //是否有房间，默认0，0-否，1-是

    private Integer status; //状态：0删除 1正常 2禁用
    private String uuid;   //手机UUID
    private String time;              //通行时间

    private long remainTime;
    private Integer errorCount;
//    private String clientNumber;    // 第三方用户账号
//    private String clientPwd;       // 第三方用户密码
    private String clientToken;     // 第三方用户token
//    private String clientUserId;    // 第三方用户id

    private List<AppUserOwnProjectVO> projects;

    private String hasNewMsg;       // 1、当前项目下有新消息,0、无新消息
    private String roomId;          // 欠费的房间Id

    private String guestType = "0"; // 用户类型，0住户，1游客

    private int   isVip = 0;// 是否是vip，1-VIP，0-不是vip
    private Integer bluetoothThreshold;      //项目蓝牙阈值




    public AppUserCacheVO(){

    }

    public AppUserCacheVO(String userId, String phoneNo, String token){
        this.userId = userId;
        this.phoneNo = phoneNo;
        this.token = token;
    }

    public AppUserCacheVO(String userId, String userName, String nickName, String phoneNo, String sex, String token){
        this.userId = userId;
        this.userName = userName;
        this.nickName = nickName;
        this.phoneNo = phoneNo;
        this.sex = sex;
        this.token = token;
    }


    public AppUserCacheVO(Integer id,String userId,String userName,String nickName,String phoneNo,String email,String photoUrl,String sex,String token,String loginDevice,String currentProjectId,String currentProjectName,Integer status,String uuid){
        this.id = id;
        this.userId = userId;
        this.userName = userName;
        this.nickName = nickName;
        this.phoneNo = phoneNo;
        this.email = email;
        this.photoUrl = photoUrl;
        this.sex = sex;
        this.token = token;
        this.loginDevice = loginDevice;
        this.currentProjectId = currentProjectId;
        this.currentProjectName = currentProjectName;
        this.setStatus(status);
        this.uuid = uuid;
    }




}
